package com.jmu.bishe.entity;

import java.util.Date;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

/**
 * Deal entity. @author MyEclipse Persistence Tools
 */
@Entity
@Table(name = "DEAL", schema = "HUANG")
public class Deal implements java.io.Serializable {

	private static final long serialVersionUID = -4729133031213503839L;
	private String id;
	private String oid;
	private Double finalPrice;
	private Date dealTime;

	// Constructors

	/** default constructor */
	public Deal() {
	}

	/** minimal constructor */
	public Deal(String id) {
		this.id = id;
	}

	/** full constructor */
	public Deal(String id, String oid, Double finalPrice, Date dealTime) {
		this.id = id;
		this.oid = oid;
		this.finalPrice = finalPrice;
		this.dealTime = dealTime;
	}

	// Property accessors
	@Id
	@Column(name = "ID", unique = true, nullable = false, length = 20)
	public String getId() {
		return this.id;
	}

	public void setId(String id) {
		this.id = id;
	}

	@Column(name = "OID", length = 20)
	public String getOid() {
		return this.oid;
	}

	public void setOid(String oid) {
		this.oid = oid;
	}

	@Column(name = "FINAL_PRICE", precision = 126, scale = 0)
	public Double getFinalPrice() {
		return this.finalPrice;
	}

	public void setFinalPrice(Double finalPrice) {
		this.finalPrice = finalPrice;
	}

	@Temporal(TemporalType.DATE)
	@Column(name = "DEAL_TIME", length = 7)
	public Date getDealTime() {
		return this.dealTime;
	}

	public void setDealTime(Date dealTime) {
		this.dealTime = dealTime;
	}

}